<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Eigen: Eigen::IOFormat Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(function() { init_search(); });
/* @license-end */
</script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="eigendoxy.css" rel="stylesheet" type="text/css">
<!--  -->
<script type="text/javascript" src="eigen_navtree_hacks.js"></script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Eigen_Silly_Professor_64x64.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname"><a href="http://eigen.tuxfamily.org">Eigen</a>
   &#160;<span id="projectnumber">3.4.90 (git rev 67eeba6e720c5745abc77ae6c92ce0a44aa7b7ae)</span>
   </div>
  </td>
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.svg"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
          </span>
        </div>
</td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('structEigen_1_1IOFormat.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="structEigen_1_1IOFormat-members.html">List of all members</a> &#124;
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Eigen::IOFormat Class Reference<div class="ingroups"><a class="el" href="group__DenseMatrixManipulation__chapter.html">Dense matrix and array manipulation</a> &raquo; <a class="el" href="group__DenseMatrixManipulation__Reference.html">Reference</a> &raquo; <a class="el" href="group__Core__Module.html">Core module</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Stores a set of parameters controlling the way matrices are printed. </p>
<p>List of available parameters:</p><ul>
<li><b>precision</b> number of digits for floating point values, or one of the special constants <code>StreamPrecision</code> and <code>FullPrecision</code>. The default is the special value <code>StreamPrecision</code> which means to use the stream's own precision setting, as set for instance using <code>cout.precision(3)</code>. The other special value <code>FullPrecision</code> means that the number of digits will be computed to match the full precision of each floating-point type.</li>
<li><b>flags</b> an OR-ed combination of flags, the default value is 0, the only currently available flag is <code>DontAlignCols</code> which allows to disable the alignment of columns, resulting in faster code.</li>
<li><b>coeffSeparator</b> string printed between two coefficients of the same row</li>
<li><b>rowSeparator</b> string printed between two rows</li>
<li><b>rowPrefix</b> string printed at the beginning of each row</li>
<li><b>rowSuffix</b> string printed at the end of each row</li>
<li><b>matPrefix</b> string printed at the beginning of the matrix</li>
<li><b>matSuffix</b> string printed at the end of the matrix</li>
<li><b>fill</b> character printed to fill the empty space in aligned columns</li>
</ul>
<p>Example: </p><div class="fragment"><div class="line">std::string sep = <span class="stringliteral">&quot;\n----------------------------------------\n&quot;</span>;</div>
<div class="line"><a class="code" href="group__matrixtypedefs.html#ga84e9fd068879d808012bb6d5dbfecb17">Matrix3d</a> m1;</div>
<div class="line">m1 &lt;&lt; 1.111111, 2, 3.33333, 4, 5, 6, 7, 8.888888, 9;</div>
<div class="line"> </div>
<div class="line"><a class="code" href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">IOFormat</a> CommaInitFmt(StreamPrecision, DontAlignCols, <span class="stringliteral">&quot;, &quot;</span>, <span class="stringliteral">&quot;, &quot;</span>, <span class="stringliteral">&quot;&quot;</span>, <span class="stringliteral">&quot;&quot;</span>, <span class="stringliteral">&quot; &lt;&lt; &quot;</span>, <span class="stringliteral">&quot;;&quot;</span>);</div>
<div class="line"><a class="code" href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">IOFormat</a> CleanFmt(4, 0, <span class="stringliteral">&quot;, &quot;</span>, <span class="stringliteral">&quot;\n&quot;</span>, <span class="stringliteral">&quot;[&quot;</span>, <span class="stringliteral">&quot;]&quot;</span>);</div>
<div class="line"><a class="code" href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">IOFormat</a> OctaveFmt(StreamPrecision, 0, <span class="stringliteral">&quot;, &quot;</span>, <span class="stringliteral">&quot;;\n&quot;</span>, <span class="stringliteral">&quot;&quot;</span>, <span class="stringliteral">&quot;&quot;</span>, <span class="stringliteral">&quot;[&quot;</span>, <span class="stringliteral">&quot;]&quot;</span>);</div>
<div class="line"><a class="code" href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">IOFormat</a> HeavyFmt(FullPrecision, 0, <span class="stringliteral">&quot;, &quot;</span>, <span class="stringliteral">&quot;;\n&quot;</span>, <span class="stringliteral">&quot;[&quot;</span>, <span class="stringliteral">&quot;]&quot;</span>, <span class="stringliteral">&quot;[&quot;</span>, <span class="stringliteral">&quot;]&quot;</span>);</div>
<div class="line"> </div>
<div class="line">std::cout &lt;&lt; m1 &lt;&lt; sep;</div>
<div class="line">std::cout &lt;&lt; m1.format(CommaInitFmt) &lt;&lt; sep;</div>
<div class="line">std::cout &lt;&lt; m1.format(CleanFmt) &lt;&lt; sep;</div>
<div class="line">std::cout &lt;&lt; m1.format(OctaveFmt) &lt;&lt; sep;</div>
<div class="line">std::cout &lt;&lt; m1.format(HeavyFmt) &lt;&lt; sep;</div>
<div class="ttc" id="agroup__matrixtypedefs_html_ga84e9fd068879d808012bb6d5dbfecb17"><div class="ttname"><a href="group__matrixtypedefs.html#ga84e9fd068879d808012bb6d5dbfecb17">Eigen::Matrix3d</a></div><div class="ttdeci">Matrix&lt; double, 3, 3 &gt; Matrix3d</div><div class="ttdoc">3×3 matrix of type double.</div><div class="ttdef"><b>Definition:</b> Matrix.h:501</div></div>
<div class="ttc" id="astructEigen_1_1IOFormat_html_acdcc91702d45c714b11ba42db5beddb5"><div class="ttname"><a href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">Eigen::IOFormat::IOFormat</a></div><div class="ttdeci">IOFormat(int _precision=StreamPrecision, int _flags=0, const std::string &amp;_coeffSeparator=&quot; &quot;, const std::string &amp;_rowSeparator=&quot;\n&quot;, const std::string &amp;_rowPrefix=&quot;&quot;, const std::string &amp;_rowSuffix=&quot;&quot;, const std::string &amp;_matPrefix=&quot;&quot;, const std::string &amp;_matSuffix=&quot;&quot;, const char _fill=' ')</div><div class="ttdef"><b>Definition:</b> IO.h:56</div></div>
</div><!-- fragment --><p> Output: </p><pre class="fragment">1.11    2 3.33
   4    5    6
   7 8.89    9
----------------------------------------
 &lt;&lt; 1.11, 2, 3.33, 4, 5, 6, 7, 8.89, 9;
----------------------------------------
[1.111,     2, 3.333]
[    4,     5,     6]
[    7, 8.889,     9]
----------------------------------------
[1.11,    2, 3.33;
    4,    5,    6;
    7, 8.89,    9]
----------------------------------------
[[1.111111,        2,  3.33333];
 [       4,        5,        6];
 [       7, 8.888888,        9]]
----------------------------------------
</pre><dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1DenseBase.html#ab231f1a6057f28d4244145e12c9fc0c7">DenseBase::format()</a>, class <a class="el" href="classEigen_1_1WithFormat.html" title="Pseudo expression providing matrix output with given format.">WithFormat</a> </dd></dl>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:acdcc91702d45c714b11ba42db5beddb5"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structEigen_1_1IOFormat.html#acdcc91702d45c714b11ba42db5beddb5">IOFormat</a> (int _precision=StreamPrecision, int _flags=0, const std::string &amp;_coeffSeparator=&quot; &quot;, const std::string &amp;_rowSeparator=&quot;\n&quot;, const std::string &amp;_rowPrefix=&quot;&quot;, const std::string &amp;_rowSuffix=&quot;&quot;, const std::string &amp;_matPrefix=&quot;&quot;, const std::string &amp;_matSuffix=&quot;&quot;, const char _fill=' ')</td></tr>
<tr class="separator:acdcc91702d45c714b11ba42db5beddb5"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="acdcc91702d45c714b11ba42db5beddb5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acdcc91702d45c714b11ba42db5beddb5">&#9670;&nbsp;</a></span>IOFormat()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">Eigen::IOFormat::IOFormat </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>_precision</em> = <code>StreamPrecision</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>_flags</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_coeffSeparator</em> = <code>&quot;&#160;&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_rowSeparator</em> = <code>&quot;\n&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_rowPrefix</em> = <code>&quot;&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_rowSuffix</em> = <code>&quot;&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_matPrefix</em> = <code>&quot;&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>_matSuffix</em> = <code>&quot;&quot;</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char&#160;</td>
          <td class="paramname"><em>_fill</em> = <code>'&#160;'</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Default constructor, see class <a class="el" href="structEigen_1_1IOFormat.html" title="Stores a set of parameters controlling the way matrices are printed.">IOFormat</a> for the meaning of the parameters </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="IO_8h_source.html">IO.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespaceEigen.html">Eigen</a></li><li class="navelem"><a class="el" href="structEigen_1_1IOFormat.html">IOFormat</a></li>
    <li class="footer">Generated on Thu Apr 21 2022 13:07:56 for Eigen by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
